package com.ptswitch.material.pages;

import org.apache.tapestry5.EventConstants;
import org.apache.tapestry5.annotations.InjectPage;
import org.apache.tapestry5.annotations.OnEvent;

import com.ptswitch.material.pages.visitor.Login;

public class Index {

    @InjectPage
    private Login login;
    private Object comingPage;

    Object init(Object comingPage) {
        this.comingPage = comingPage;
        return comingPage;
    }

    @OnEvent(value = EventConstants.ACTIVATE)
    Object toLogin() {
        return login;
    }
}
